![]() |
ALMaSS
1.0
The Animal, Landscape and Man Simulation System
|
The class describing the beetle Egg_List objects. More...
#include <bembidion_all.h>
Public Member Functions | |
Bembidion_Egg_List (int today, Bembidion_Population_Manager *BPM, Landscape *L) | |
Egg_List class constructor. More... | |
virtual void | Step () |
Egg_List class Step code. More... | |
virtual void | BeginStep () |
Egg_List class BeginStep code. More... | |
void | AddEgg (int x, int y) |
Add an egg to the list. More... | |
void | DeleteEgg (int x, int y) |
Remove an egg from the list. More... | |
![]() | |
Bembidion_Base (int x, int y, Landscape *L, Bembidion_Population_Manager *BPM) | |
Constructor. More... | |
void | ReInit (int x, int y, Landscape *L, Bembidion_Population_Manager *BPM) |
ReInit for object pool. More... | |
virtual void | EndStep () |
EndStep - empty. More... | |
virtual void | st_Die () |
Common state Die. More... | |
void | CopyMyself (int a_beetle) |
For experimental purposes. More... | |
void | CopyMyselfB (int a_beetle) |
For experimental purposes. More... | |
![]() | |
unsigned | SupplyFarmOwnerRef () |
AnimalPosition | SupplyPosition () |
APoint | SupplyPoint () |
int | SupplyPolygonRef () |
int | Supply_m_Location_x () |
int | Supply_m_Location_y () |
virtual void | KillThis () |
virtual void | CopyMyself () |
void | SetX (int a_x) |
void | SetY (int a_y) |
TAnimal (int x, int y, Landscape *L) | |
virtual void | ReinitialiseObject (int x, int y, Landscape *L) |
Used to re-use an object - must be implemented in descendent classes. More... | |
virtual int | WhatState () |
virtual void | Dying () |
void | CheckManagement (void) |
void | CheckManagementXY (int x, int y) |
virtual bool | OnFarmEvent (FarmToDo) |
![]() | |
int | GetCurrentStateNo () |
Returns the current state number. More... | |
void | SetCurrentStateNo (int a_num) |
Sets the current state number. More... | |
bool | GetStepDone () |
Returns the step done indicator flag. More... | |
void | SetStepDone (bool a_bool) |
Sets the step done indicator flag. More... | |
virtual void | ReinitialiseObject () |
Used to re-use an object - must be implemented in descendent classes. More... | |
TALMaSSObject () | |
The constructor for TALMaSSObject. More... | |
virtual | ~TALMaSSObject () |
The destructor for TALMaSSObject. More... | |
void | OnArrayBoundsError () |
Used for debugging only, tests basic object properties. More... | |
Public Attributes | |
TListOfEggs | EggList |
The list of eggs. More... | |
![]() | |
TTypesOfBeetleState | CurrentBState |
Current behavioural state. More... | |
Bembidion_Population_Manager * | m_OurPopulation |
Pointer to the population manager. More... | |
Protected Member Functions | |
int | st_Develop () |
Egg_List state development. More... | |
void | st_Hatch () |
Egg_List state hatching. More... | |
void | DailyMortality () |
Egg_List non-temperature or density related mortality. More... | |
void | SortXR () |
![]() | |
void | CorrectWrapRound () |
Corrects wrap around co-ordinate problems. More... | |
Protected Attributes | |
int | m_DayMade |
![]() | |
int | m_Location_x |
int | m_Location_y |
Landscape * | m_OurLandscape |
![]() | |
int | m_CurrentStateNo |
The basic state number for all objects - '-1' indicates death. More... | |
bool | m_StepDone |
Indicates whether the iterative step code is done for this timestep. More... | |
The class describing the beetle Egg_List objects.
Bembidion_Egg_List::Bembidion_Egg_List | ( | int | today, |
Bembidion_Population_Manager * | BPM, | ||
Landscape * | L | ||
) |
Egg_List class constructor.
The egg list is an optimisation to reduce memory and time to run it means that there are only 365 of them possible and that each on contains all the eggs laid on that day. The only real problem is that there is no longer a link from parent to offspring - so this version cannot be used with genetics without adding the genes to the APoint struct.
References m_DayMade.
|
inline |
Add an egg to the list.
References EggList, APoint::m_x, and APoint::m_y.
Referenced by Bembidion_Population_Manager::CreateObjects().
|
virtual |
Egg_List class BeginStep code.
Reimplemented from Bembidion_Base.
References DailyMortality().
Referenced by Bembidion_Population_Manager::DoFirst().
|
protected |
Egg_List non-temperature or density related mortality.
References autumn_harrow, autumn_or_spring_plough, autumn_plough, autumn_roll, autumn_sow, bed_forming, biocide, bulb_harvest, burn_straw_stubble, cattle_out, cattle_out_low, cfg_Egg_InsecticideApplication, cfg_Egg_SoilCultivationMortality, cfg_PesticideTrialEggTreatmentMort, cut_to_hay, cut_to_silage, cut_weeds, DailyEggMort, deep_ploughing, EggList, fa_ammoniumsulphate, fa_calcium, fa_greenmanure, fa_manganesesulphate, fa_manure, fa_npk, fa_npks, fa_pk, fa_rsm, fa_sludge, fa_slurry, flammebehandling, flower_cutting, fp_ammoniumsulphate, fp_calcium, fp_greenmanure, fp_liquidNH3, fp_manganesesulphate, fp_manure, fp_npk, fp_npks, fp_pk, fp_rsm, fp_sludge, fp_slurry, fungicide_treat, g_rand_uni, glyphosate, growth_regulator, harvest, hay_bailing, hay_turning, heavy_cultivator_aggregate, herbicide_treat, hilling_up, insecticide_treat, TAnimal::m_Location_x, TAnimal::m_Location_y, TAnimal::m_OurLandscape, molluscicide, mow, PesticideTrialEggToxicMort, pigs_out, preseeding_cultivator, preseeding_cultivator_sow, product_treat, random(), row_cultivation, shallow_harrow, sleep_all_day, SortXR(), spring_harrow, spring_plough, spring_roll, spring_sow, spring_sow_with_ferti, straw_chopping, straw_covering, straw_removal, strigling, strigling_hill, strigling_sow, stubble_cultivator_heavy, stubble_harrowing, stubble_plough, Landscape::SupplyLastTreatment(), swathing, syninsecticide_treat, trial_control, trial_insecticidetreat, trial_toxiccontrol, CfgInt::value(), CfgFloat::value(), Landscape::Warn(), water, and winter_plough.
Referenced by BeginStep().
void Bembidion_Egg_List::DeleteEgg | ( | int | x, |
int | y | ||
) |
Remove an egg from the list.
|
protected |
Sort TheArray w.r.t. the current X in reverse order
References EggList.
Referenced by DailyMortality().
|
protected |
Egg_List state development.
References EggDevelConst2, m_DayMade, Bembidion_Base::m_OurPopulation, and Bembidion_Population_Manager::SupplyEDayDeg().
Referenced by Step().
|
protected |
Egg_List state hatching.
References struct_Bembidion::BPM, Bembidion_Population_Manager::CreateObjects(), EggList, struct_Bembidion::L, Population_Manager::LamdaBirth(), TAnimal::m_Location_x, TAnimal::m_Location_y, TAnimal::m_OurLandscape, Bembidion_Base::m_OurPopulation, struct_Bembidion::x, and struct_Bembidion::y.
Referenced by Step().
|
virtual |
Egg_List class Step code.
Reimplemented from Bembidion_Base.
References Bembidion_Base::CurrentBState, g_msg, TALMaSSObject::m_CurrentStateNo, TAnimal::m_OurLandscape, TALMaSSObject::m_StepDone, st_Develop(), st_Hatch(), tobs_EDeveloping, tobs_Hatching, tobs_Initiation, MapErrorMsg::Warn(), Landscape::Warn(), and WARN_BUG.
TListOfEggs Bembidion_Egg_List::EggList |
The list of eggs.
Referenced by AddEgg(), DailyMortality(), Bembidion_Population_Manager::DoFirst(), Bembidion_Population_Manager::Probe(), SortXR(), and st_Hatch().
|
protected |
Records the day hatched for development calculations
Referenced by Bembidion_Egg_List(), and st_Develop().